gtk4.git
5 years agoinfobar: Add gtk_info_bar_add/remove_child
Matthias Clasen [Thu, 7 May 2020 16:49:15 +0000 (12:49 -0400)]
infobar: Add gtk_info_bar_add/remove_child

This is a replacement for container api that is going away.

5 years agoinfobar: Add gtk_info_bar_remove_action_widget
Matthias Clasen [Thu, 7 May 2020 16:28:33 +0000 (12:28 -0400)]
infobar: Add gtk_info_bar_remove_action_widget

This is mainly for completeness, since gtk_container_remove
will not work for those anymore.

5 years agopaned: Redo the api
Matthias Clasen [Thu, 7 May 2020 12:30:39 +0000 (08:30 -0400)]
paned: Redo the api

This commit is porting GtkPaned to be derived
from GtkWidget instead of GtkContainer, while adding
start-child and end-child properties. The existing
properties are renamed to follow the start/end naming
scheme, and we add proper getters and setters.

Update all users.

See #2719

5 years agopaned: Drop some dead code
Matthias Clasen [Thu, 7 May 2020 05:02:01 +0000 (01:02 -0400)]
paned: Drop some dead code

5 years agoiconview: Derive from GtkWidget
Matthias Clasen [Thu, 7 May 2020 04:47:25 +0000 (00:47 -0400)]
iconview: Derive from GtkWidget

GtkIconView is not a container.

5 years agoexpander: Derive from GtkWidget
Matthias Clasen [Thu, 7 May 2020 04:16:08 +0000 (00:16 -0400)]
expander: Derive from GtkWidget

We want to remove GtkBin and GtkContainer as they don't
provide much useful functionality anymore. This requires
us to move get_request_mode and compute_expand down.

See #2719

5 years agoUse gtk_expander_set_child throughout
Matthias Clasen [Thu, 7 May 2020 04:05:51 +0000 (00:05 -0400)]
Use gtk_expander_set_child throughout

Replace all uses of gtk_container_add on expanders
with gtk_expander_set_child.

5 years agoexpander: Add a child property
Matthias Clasen [Thu, 7 May 2020 04:02:42 +0000 (00:02 -0400)]
expander: Add a child property

5 years agoactionbar: Derive from GtkWidget
Matthias Clasen [Thu, 7 May 2020 03:54:11 +0000 (23:54 -0400)]
actionbar: Derive from GtkWidget

GtkContainer is going away.

5 years agoactionbar: Add gtk_action_bar_remove
Matthias Clasen [Thu, 7 May 2020 03:42:32 +0000 (23:42 -0400)]
actionbar: Add gtk_action_bar_remove

This is a replacement for gtk_container_remove.

5 years agotreeview: Derive from GtkWidget
Matthias Clasen [Tue, 5 May 2020 11:27:04 +0000 (07:27 -0400)]
treeview: Derive from GtkWidget

Drop the GtkContainer vfuncs.

5 years agotreeview: Stop using container api
Matthias Clasen [Tue, 5 May 2020 02:40:15 +0000 (22:40 -0400)]
treeview: Stop using container api

5 years agotextview: Derive from GtkWidget
Matthias Clasen [Tue, 5 May 2020 02:30:46 +0000 (22:30 -0400)]
textview: Derive from GtkWidget

Drop the GtkContainer vfuncs. As a replacement for
gtk_container_remove, make gtk_text_view_remove public.

5 years agodragicon: drop gtkcontainer.h include
Matthias Clasen [Fri, 8 May 2020 23:57:34 +0000 (19:57 -0400)]
dragicon: drop gtkcontainer.h include

We don't need it anymore here.

5 years agotextviewchild: Don't leak children
Matthias Clasen [Tue, 12 May 2020 00:31:14 +0000 (20:31 -0400)]
textviewchild: Don't leak children

Like everybody else, GtkTextViewChild must
unparent its children in dispose.

5 years agoFix a leftover window
Matthias Clasen [Fri, 8 May 2020 16:27:25 +0000 (12:27 -0400)]
Fix a leftover window

We were still using container api on a window here.

5 years agoFix a leftover list box child
Matthias Clasen [Fri, 8 May 2020 16:26:50 +0000 (12:26 -0400)]
Fix a leftover list box child

We were still using container api on a list box child here.

5 years agowindow: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:30:12 +0000 (01:30 -0400)]
window: Fix accessible implementation

Now that GtkWindow is no longer a container,
update the accessible implementation to match.

5 years agostatusbar: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:29:17 +0000 (01:29 -0400)]
statusbar: Fix accessible implementation

Now that GtkStatusBar is no longer a container,
update the accessible implementation to match.

5 years agoscrolledwindow: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:28:30 +0000 (01:28 -0400)]
scrolledwindow: Fix accessible implementation

Now that GtkScrolledWindow is no longer a container,
update the accessible implementation to match.

5 years agopopover: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:27:41 +0000 (01:27 -0400)]
popover: Fix accessible implementation

Now that GtkPopover is no longer a container,
update the accessible implementation to match.

5 years agoframe: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:25:49 +0000 (01:25 -0400)]
frame: Fix accessible implementation

Now that GtkFrame is no longer a container,
update the accessible implementation to match.

5 years agoflowboxchild: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:24:48 +0000 (01:24 -0400)]
flowboxchild: Fix accessible implementation

Now that GtkFlowBoxChild is no longer a container,
update the accessible implementation to match.

5 years agocombobox: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:22:30 +0000 (01:22 -0400)]
combobox: Fix accessible implementation

Now that GtkComboBox is no longer a container,
update the accessible implementation to match.

5 years agolistboxrow: Fix the accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:20:53 +0000 (01:20 -0400)]
listboxrow: Fix the accessible implementation

GtkListBoxRow is no longer a container, update
the accessible implementation to match.

5 years agobutton: Fix accessible implementation
Matthias Clasen [Fri, 8 May 2020 05:11:22 +0000 (01:11 -0400)]
button: Fix accessible implementation

Now that GtkButton is no longer a container,
update the accessible implementation to match.

5 years agoCosmetics: Replace GtkContainer in an error message
Matthias Clasen [Fri, 8 May 2020 13:13:37 +0000 (09:13 -0400)]
Cosmetics: Replace GtkContainer in an error message

GtkWidget is not that much better here, unfortunately.

Adapt the testsuite to match.

5 years agoMerge branch 'matthiasc/for-master' into 'master'
Matthias Clasen [Mon, 11 May 2020 19:08:53 +0000 (19:08 +0000)]
Merge branch 'matthiasc/for-master' into 'master'

print-editor: Bring back the menubar

See merge request GNOME/gtk!1875

5 years agoMerge branch 'wip/exalm/2242-test' into 'master'
Matthias Clasen [Mon, 11 May 2020 18:51:20 +0000 (18:51 +0000)]
Merge branch 'wip/exalm/2242-test' into 'master'

tests: Add a headerbar-in-window test case

See merge request GNOME/gtk!1878

5 years agoMerge branch 'wip/tintou/doc-fixes' into 'master'
Matthias Clasen [Mon, 11 May 2020 18:40:34 +0000 (18:40 +0000)]
Merge branch 'wip/tintou/doc-fixes' into 'master'

docs: Fix several missing references in the documentation

See merge request GNOME/gtk!1874

5 years agoprinteroptionwidget: Avoid a critical
Matthias Clasen [Mon, 11 May 2020 18:26:31 +0000 (14:26 -0400)]
printeroptionwidget: Avoid a critical

The new_location can be NULL, as we clearly
knew earlier in the function. We've forgotten
about that by the time we unref it :(

5 years agoheaderbar: Don't clean up other widget children
Matthias Clasen [Mon, 11 May 2020 18:25:57 +0000 (14:25 -0400)]
headerbar: Don't clean up other widget children

The parent of the title_widget is the center box,
it needs to call gtk_widget_unparent on it.

5 years agoMerge branch 'cherry-pick-6d8fb83a' into 'master'
Emmanuele Bassi [Mon, 11 May 2020 18:25:39 +0000 (18:25 +0000)]
Merge branch 'cherry-pick-6d8fb83a' into 'master'

aboutdialog: Update precondition checks for new licenses added in 3.24.20

Closes #2734

See merge request GNOME/gtk!1877

5 years agofilechooserdialog: Be more careful with widgets
Matthias Clasen [Mon, 11 May 2020 18:23:58 +0000 (14:23 -0400)]
filechooserdialog: Be more careful with widgets

We were stepping on our own toes, by first setting
up a save entry and telling the filechooserwidget
about it, and then nuking it by setting a title
on the headerbar. The filechooserwidget wasn't
ready for the entry to die without anybody telling
it.

This fixes a crash when using the filechooser for
print-to-file in the print dialog.

5 years agotests: Add a headerbar-in-window test case
Alexander Mikhaylenko [Mon, 11 May 2020 17:37:58 +0000 (22:37 +0500)]
tests: Add a headerbar-in-window test case

See https://gitlab.gnome.org/GNOME/gtk/-/issues/2242

5 years agoaboutdialog: Update precondition checks for new licenses added in 3.24.20
Simon McVittie [Mon, 11 May 2020 17:12:08 +0000 (17:12 +0000)]
aboutdialog: Update precondition checks for new licenses added in 3.24.20

To avoid making this mistake again, add a static assertion that the
enum is in sync with gtk_license_info, and use the length of
gtk_license_info for the precondition check.

Signed-off-by: Simon McVittie <smcv@debian.org>
Resolves: #2734

5 years agodocs: Fix several missing references in the documentation
Corentin Noël [Mon, 11 May 2020 16:47:20 +0000 (18:47 +0200)]
docs: Fix several missing references in the documentation

This fixes several typos and missing references

5 years agoMerge branch 'window-destroy' into 'master'
Matthias Clasen [Mon, 11 May 2020 17:15:59 +0000 (17:15 +0000)]
Merge branch 'window-destroy' into 'master'

Drop gtk_widget_destroy

See merge request GNOME/gtk!1864

5 years agoprint-editor: Bring back the menubar
Matthias Clasen [Mon, 11 May 2020 16:55:15 +0000 (12:55 -0400)]
print-editor: Bring back the menubar

This was the one place where we relied on
the menubar fallback in GtkApplicationWindow.

So turn it on explicitly.

5 years agoUpdate the docs
Matthias Clasen [Sun, 10 May 2020 00:01:21 +0000 (20:01 -0400)]
Update the docs

Remove various references to gtk_widget_destroy in the docs.

5 years agoUnset tooltip window earlier
Matthias Clasen [Sat, 9 May 2020 20:46:40 +0000 (16:46 -0400)]
Unset tooltip window earlier

This avoids a crash when the tooltip window tries
to update its action muxers.

5 years agowindow: Remove _set_has_user_ref_count
Matthias Clasen [Sat, 9 May 2020 19:55:20 +0000 (15:55 -0400)]
window: Remove _set_has_user_ref_count

5 years agotestsuite: add widget refcount test case
Timm Bäder [Tue, 26 Sep 2017 15:04:51 +0000 (17:04 +0200)]
testsuite: add widget refcount test case

Testing toplevels and popovers.

5 years agowidget: Drop gtk_widget_destroy
Matthias Clasen [Sat, 9 May 2020 19:45:54 +0000 (15:45 -0400)]
widget: Drop gtk_widget_destroy

5 years agowindow: Implement gtk_window_destroy
Matthias Clasen [Sat, 9 May 2020 19:20:59 +0000 (15:20 -0400)]
window: Implement gtk_window_destroy

Don't call gtk_widget_destroy; instead implement
gtk_window_destroy outselves by removing the window
from the toplevel lista and dropping the reference that
GTK holds.

5 years agoReplace gtk_widget_destroy everywhere
Matthias Clasen [Sat, 9 May 2020 14:33:02 +0000 (10:33 -0400)]
Replace gtk_widget_destroy everywhere

Replace all remaining uses of gtk_widget_destroy
by gtk_container_remove or g_object_unref.

5 years agoUse gtk_window_destroy
Matthias Clasen [Sat, 9 May 2020 14:26:22 +0000 (10:26 -0400)]
Use gtk_window_destroy

Replace calls to gtk_widget_destroy on windows
with gtk_window_destroy.

5 years agowindow: Add gtk_window_destroy
Matthias Clasen [Sat, 9 May 2020 13:30:29 +0000 (09:30 -0400)]
window: Add gtk_window_destroy

This is a replacement for gtk_widget_destroy for toplevels.
For now, it is just a wrapper.

5 years agonativedialog: Do not ref the transient_for parent
Matthias Clasen [Sat, 9 May 2020 20:05:08 +0000 (16:05 -0400)]
nativedialog: Do not ref the transient_for parent

gtk_window_set_transient_for does not ref its parent either. This is
important because a child widget of the parent might be the one calling
this function.

This was showing up as widget-factory not existing on close after
opening the file chooser.

5 years agotestsuite: Clean up unexpected children
Matthias Clasen [Sat, 9 May 2020 21:31:18 +0000 (17:31 -0400)]
testsuite: Clean up unexpected children

If you call gtk_widget_set_parent on an unsuspecting
parent widget, it is your reponsibility to clean up
before the parent gets finalized.

5 years agopopover: Fix a reference leak
Matthias Clasen [Sat, 9 May 2020 19:20:15 +0000 (15:20 -0400)]
popover: Fix a reference leak

Don't leak the reference to the default widget.

5 years agofilechooserdialog: Fix disposing
Matthias Clasen [Sat, 9 May 2020 19:19:39 +0000 (15:19 -0400)]
filechooserdialog: Fix disposing

We need to drop our widgetry in dispose to prevent
leakage.

5 years agocolorchooserdialog: Fix disposing
Matthias Clasen [Sat, 9 May 2020 18:14:55 +0000 (14:14 -0400)]
colorchooserdialog: Fix disposing

We need to drop our widgetry in dispose to prevent
leakage.

5 years agofontchooserdialog: Fix disposing
Matthias Clasen [Sat, 9 May 2020 18:10:38 +0000 (14:10 -0400)]
fontchooserdialog: Fix disposing

We need to drop our widgetry in dispose to prevent
leakage.

5 years agoDrop gtk_widget_destroyed
Matthias Clasen [Sat, 9 May 2020 16:09:13 +0000 (12:09 -0400)]
Drop gtk_widget_destroyed

Use g_object_add_weak_pointer or a weak reference instead.

5 years agoStop using gtk_widget_destroyed
Matthias Clasen [Sat, 9 May 2020 16:03:11 +0000 (12:03 -0400)]
Stop using gtk_widget_destroyed

Replace all internal use of gtk_widget_destroyed
by g_object_add_weak_pointer.

5 years agoMerge branch 'wip/exalm/test' into 'master'
Matthias Clasen [Mon, 11 May 2020 15:52:24 +0000 (15:52 +0000)]
Merge branch 'wip/exalm/test' into 'master'

Fix (most of the) tests

See merge request GNOME/gtk!1873

5 years agoMerge branch 'teardown-cleanup-2' into 'master'
Matthias Clasen [Mon, 11 May 2020 15:23:40 +0000 (15:23 +0000)]
Merge branch 'teardown-cleanup-2' into 'master'

Treeview teardown cleanup

See merge request GNOME/gtk!1872

5 years agotests: Stop explicitly showing widgets
Alexander Mikhaylenko [Mon, 11 May 2020 14:57:25 +0000 (19:57 +0500)]
tests: Stop explicitly showing widgets

5 years agotests: Remove redundant image from testdialog
Alexander Mikhaylenko [Mon, 11 May 2020 15:03:51 +0000 (20:03 +0500)]
tests: Remove redundant image from testdialog

5 years agotests: Connect signal properly for testvolumebutton
Alexander Mikhaylenko [Mon, 11 May 2020 14:54:32 +0000 (19:54 +0500)]
tests: Connect signal properly for testvolumebutton

5 years agotests: Remove orientation from testvolumebutton
Alexander Mikhaylenko [Mon, 11 May 2020 14:53:31 +0000 (19:53 +0500)]
tests: Remove orientation from testvolumebutton

GtkVolumeButton isn't orientable anymore.

5 years agotest: Stop using stock-size for teestverticalcells
Alexander Mikhaylenko [Mon, 11 May 2020 14:51:18 +0000 (19:51 +0500)]
test: Stop using stock-size for teestverticalcells

5 years agotests: Fix testtreeelistmodel
Alexander Mikhaylenko [Mon, 11 May 2020 14:47:58 +0000 (19:47 +0500)]
tests: Fix testtreeelistmodel

Stop using GtkContainer API for GtkListBoxRow and GtkToggleButton.

5 years agotests: Fix teststackedheader
Alexander Mikhaylenko [Mon, 11 May 2020 14:32:52 +0000 (19:32 +0500)]
tests: Fix teststackedheader

Connect to signals programmatically.

5 years agotestsuite: Enable the remaining template tests
Matthias Clasen [Sun, 10 May 2020 21:54:49 +0000 (17:54 -0400)]
testsuite: Enable the remaining template tests

These are no longer failing.

5 years agotreeview: Break reference cycles on unroot
Matthias Clasen [Mon, 11 May 2020 14:00:12 +0000 (10:00 -0400)]
treeview: Break reference cycles on unroot

It is a bad idea to have such cycles in the first place,
and there is no need to let them linger past unroot.

This stop the treeview depending on run_dispose to get
freed, a simple unparent will work now.

5 years agotests: Fix teststack "add icon" button
Alexander Mikhaylenko [Mon, 11 May 2020 14:27:41 +0000 (19:27 +0500)]
tests: Fix teststack "add icon" button

5 years agoMerge branch 'wip/baedert/for-master' into 'master'
Matthias Clasen [Mon, 11 May 2020 14:24:45 +0000 (14:24 +0000)]
Merge branch 'wip/baedert/for-master' into 'master'

Wip/baedert/for master

See merge request GNOME/gtk!1867

5 years agotests: Fix testselectionmode
Alexander Mikhaylenko [Mon, 11 May 2020 14:21:03 +0000 (19:21 +0500)]
tests: Fix testselectionmode

Stop using <packing/> and GtkContainer API for random widgets.

5 years agoUpdate Ukrainian translation
Yuri Chornoivan [Mon, 11 May 2020 14:20:13 +0000 (14:20 +0000)]
Update Ukrainian translation

5 years agotests: Fix testoverlay
Alexander Mikhaylenko [Mon, 11 May 2020 14:13:04 +0000 (19:13 +0500)]
tests: Fix testoverlay

Stop using child properties and margin property.

5 years agotests: Simplify testorientable
Alexander Mikhaylenko [Mon, 11 May 2020 14:08:56 +0000 (19:08 +0500)]
tests: Simplify testorientable

Since GtkButtonBox is gone, remove the separator and change grid to box.

5 years agotests: Remove testmodelbutton
Alexander Mikhaylenko [Mon, 11 May 2020 14:03:53 +0000 (19:03 +0500)]
tests: Remove testmodelbutton

GtkModelButton is private now, so it can't work anymore.

5 years agotests: Remove use-popover from testmenubutton
Alexander Mikhaylenko [Mon, 11 May 2020 13:55:15 +0000 (18:55 +0500)]
tests: Remove use-popover from testmenubutton

The corresponding property doesn't exist anymore.

5 years agotests: Fix testlogout
Alexander Mikhaylenko [Mon, 11 May 2020 13:54:53 +0000 (18:54 +0500)]
tests: Fix testlogout

Stop using GtkApplication::quit signal.

5 years agotests: Fix testiconview
Alexander Mikhaylenko [Mon, 11 May 2020 13:54:23 +0000 (18:54 +0500)]
tests: Fix testiconview

Stop using GtkContainer API for GtkPopover.

5 years agotests: Fix testheightforwidth layout
Alexander Mikhaylenko [Mon, 11 May 2020 13:39:32 +0000 (18:39 +0500)]
tests: Fix testheightforwidth layout

Stop using child properties and setting visible=true everywhere.

5 years agotests: Expand content for testheaderbar
Alexander Mikhaylenko [Mon, 11 May 2020 13:31:59 +0000 (18:31 +0500)]
tests: Expand content for testheaderbar

5 years agotests: Fix testgtk
Alexander Mikhaylenko [Mon, 11 May 2020 13:11:48 +0000 (18:11 +0500)]
tests: Fix testgtk

An assorted collection of fixes.

5 years agoMerge branch 'matthiasc/for-master' into 'master'
Matthias Clasen [Mon, 11 May 2020 12:51:08 +0000 (12:51 +0000)]
Merge branch 'matthiasc/for-master' into 'master'

Matthiasc/for master

Closes #2729 and #2730

See merge request GNOME/gtk!1870

5 years agomenubutton: Cosmetics
Matthias Clasen [Mon, 11 May 2020 04:17:53 +0000 (00:17 -0400)]
menubutton: Cosmetics

Fix a few typos in the docs.

5 years agoRefresh the tutorial examples
Matthias Clasen [Mon, 11 May 2020 01:26:19 +0000 (21:26 -0400)]
Refresh the tutorial examples

Redo this series of examples from 2013, and adapt it to modern
way of doing things. The biggest differences are that we use
a headerbar right from the start, and don't mention the app
menu.

Fixes: #2730
5 years agoapplicationswindow: Make show-menubar FALSE by default
Matthias Clasen [Mon, 11 May 2020 00:15:31 +0000 (20:15 -0400)]
applicationswindow: Make show-menubar FALSE by default

The fallback to the menubar is not a good sight,
we should not do that by default.

5 years agodocs: Cosmetic updates to the tutorial
Matthias Clasen [Sun, 10 May 2020 22:23:32 +0000 (18:23 -0400)]
docs: Cosmetic updates to the tutorial

Since the meson conversion, we are no longer expanding
gtk-doc references in this file, so take them out. And
touch up the wording in various places.

5 years agoClean up a leak in a test
Matthias Clasen [Sun, 10 May 2020 21:13:26 +0000 (17:13 -0400)]
Clean up a leak in a test

One of the treeview tests was calling gtk_widget_destroy
on a child instead of the toplevel, which leaks the toplevel
unnecessarily. Plus, we're moving towards allowing destroy
only on toplevels.

5 years agotreeviewcolumn: Another case of box <> frame confusion
Matthias Clasen [Sun, 10 May 2020 18:07:17 +0000 (14:07 -0400)]
treeviewcolumn: Another case of box <> frame confusion

Don't call your boxes frames, folks!

5 years agobuilderscope: Fix finalize <> dispose confusion
Matthias Clasen [Sun, 10 May 2020 17:29:40 +0000 (13:29 -0400)]
builderscope: Fix finalize <> dispose confusion

Don't chain up to dispose if you implement finalize.

This fix s courtesy of GOBJECT_DEBUG=objects.

5 years agoprint dialog: Fix frame <> box confusion
Matthias Clasen [Sun, 10 May 2020 17:18:22 +0000 (13:18 -0400)]
print dialog: Fix frame <> box confusion

It is a bad idea to have a GtkBox called frame, event
if it started out its existence as a GtkFrame.

5 years agotreeview: Ensure search popover is properly inserted
Matthias Clasen [Sun, 10 May 2020 17:16:52 +0000 (13:16 -0400)]
treeview: Ensure search popover is properly inserted

The css tree and the widget tree are not in sync, so we need
to explicitly set the parent of the css node before inserting
the widget, or else we end up with critical warnings and a
non-working popover.

This can be seen in the print dialog, when moving the focus
to the printer list.

5 years agoprint-editor: Cosmetics
Matthias Clasen [Sun, 10 May 2020 16:59:27 +0000 (12:59 -0400)]
print-editor: Cosmetics

Make the about dialog a bit less barren.

5 years agoprint-editor: Fix a critical
Matthias Clasen [Sun, 10 May 2020 16:53:37 +0000 (12:53 -0400)]
print-editor: Fix a critical

GtkWindow is no longer a container, so don't call
gtk_container_add on it.

5 years agoMerge branch 'focusable-property' into 'master'
Matthias Clasen [Mon, 11 May 2020 11:23:15 +0000 (11:23 +0000)]
Merge branch 'focusable-property' into 'master'

Focusable property

See merge request GNOME/gtk!1834

5 years agoMerge branch 'aperezdc/vk-result-range-size' into 'master'
Emmanuele Bassi [Mon, 11 May 2020 10:02:53 +0000 (10:02 +0000)]
Merge branch 'aperezdc/vk-result-range-size' into 'master'

Fix build issue due to missing VK_RESULT_RANGE_SIZE

See merge request GNOME/gtk!1871

5 years agoFix build issue due to missing VK_RESULT_RANGE_SIZE
Adrian Perez de Castro [Mon, 11 May 2020 07:07:41 +0000 (10:07 +0300)]
Fix build issue due to missing VK_RESULT_RANGE_SIZE

Conditionally check whether the Vulkan headers version defines
VK_RESULT_RANGE_SIZE, and avoid using it for version >=140. The
following comming in Vulkan-Headers has removed the enum value:

  https://github.com/KhronosGroup/Vulkan-Headers/commit/0c5351f5e9114d3e9033aeae51d036a3d201c082#diff-4febd94c0666d59030d8b1dd20c72403

5 years agoClarify docs around focus.
Matthias Clasen [Mon, 11 May 2020 04:29:41 +0000 (00:29 -0400)]
Clarify docs around focus.

5 years agoRemove lots of focus vfuncs
Matthias Clasen [Mon, 11 May 2020 03:58:30 +0000 (23:58 -0400)]
Remove lots of focus vfuncs

In many cases, the default widget vfuncs work just fine,
combined with setting focusable.

5 years agowidget: Fix gtk_widget_focus_all for !focusable
Matthias Clasen [Mon, 11 May 2020 03:42:02 +0000 (23:42 -0400)]
widget: Fix gtk_widget_focus_all for !focusable

This was a case that wasn't handle properly when
the focus is entering from the outside, in forward
direction.

5 years agowidget: Add a :focusable property
Matthias Clasen [Tue, 5 May 2020 18:57:21 +0000 (14:57 -0400)]
widget: Add a :focusable property

Add back a property that determines whether an individual
widget will accept focus or not. :can-focus prevents the
focus from ever entering the entire widget hierarchy
below a widget, and :focusable just determines if grabbing
the focus to the widget itself will succeed.

See #2686

5 years agotests: Fix testgmenu
Alexander Mikhaylenko [Sun, 10 May 2020 23:58:36 +0000 (04:58 +0500)]
tests: Fix testgmenu

GtkMenuButton isn't a GtkButton anymore.